package Manu;

import Function.*;

import java.util.Scanner;

public class Manu {
    public static void manu(){
        System.out.println("-----欢迎来到用户管理系统-----");
        System.out.println("1.增加商品到购物车");
        System.out.println("2.删除购物车中的商品");
        System.out.println("3.查询商品菜单");
        System.out.println("4.查看购物车");
        System.out.println("5.确认购买");
        System.out.println("请输入你要进行的操作编号：");
        Scanner scanner = new Scanner(System.in);
        int sc = scanner.nextInt();
        switch(sc){
            case 1:
                Add.add();
                break;
            case 2:
                Delete.delete();
                break;
            case 3:
                Found<String> foundGoods = new Found<>();
                System.out.println("---商品信息---");
                System.out.println("编号，名称，价格");
                foundGoods.show("001,饮料,3元");
                foundGoods.show("002,牛奶,4元");
                foundGoods.show("003,面包,5元");
                foundGoods.show("004,水果,6元");
                foundGoods.show("005,零食,7元");
                manu();
                break;
            case 4:
                ShoppingCart.shoppingCart();
                break;
            case 5:
                Buy.buy();
                break;
            default:
                System.out.println("请正确输入！");
        }
    }
}
